<script>
    var request = new XMLHttpRequest();
    request.open('GET', 'http://test', false);
    request.send(null);
    window._testResult = request.responseText;
</script>